package ClassExercise;

public class Student {
    private int age;
    private String name;

    public Student(){

    }
    public Student(int age,String name){
        this.age=age;
        this.name=name;
    }
    public void studentStudy(){
        System.out.println("好好学习！");
    }

    public void exam(){
        System.out.println("好好学习就能考试通过！！");
    }

    public int getAge() {
        return age;
    }

    public String getName() {
        return name;
    }

    @Override
    public String toString() {
        return "Student{" +
                "age=" + age +
                ", name='" + name + '\'' +
                '}';
    }
}
